<?php

require_once 'Zend/View/Helper/Abstract.php';


//TODO: don't use Zend namespace, use our own
class Zend_View_Helper_ItemCount extends Zend_View_Helper_Abstract
{
    public function itemCount($count, $zero = NULL, $one = NULL, $many = NULL)
    {
		switch (intval($count)) {
		case 0: return sprintf($zero, 0);
		case 1: return sprintf($one, 1);
		default: return sprintf($many, intval($count));
		}
	}
}
